<template>
    <div class="page-share-poster">
        <div class="title text-center color-red text-normal">点击图片后长按分享或保存相册</div>
        <div class="image-box">
            <img  @click="onClickImage" class="image" :src="placeholderImg" mode="widthFix" />
        </div>
    </div>
</template>

<script lang="ts">
import store from '@/store';
import {
    placeholderImg,
} from '@/lib/utils';

import { Component, Vue } from 'vue-property-decorator';

@Component({
    name: 'SharePoster',
})
export default class SharePoster extends Vue {
    public placeholderImg: any = placeholderImg;

    /**
     * 点击图片
     */
    public onClickImage() {
        wx.previewImage({
            current: '',
            urls: [ this.placeholderImg ],
        });
    }
}
</script>

<style lang="less">
@import "../../lib/style/mixins.less";

.page-share-poster {
    .title {
        padding: 40rpx 0;
    }
    .image-box {
        width: 256px;
        margin: 0 auto;
        image {
            width: 100%;
        }
    }
}

</style>
